//
//  TimeUpItemCell.m
//  TerritoryShopkeeper
//
//  Created by xiaowu on 2017/12/7.
//  Copyright © 2017年 ZDQK. All rights reserved.
//

#import "TimeUpItemCell.h"

@implementation TimeUpItemCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    
    self.iconImageView.backgroundColor = [UIColor imageEDBackgroundColor];
    
    self.nameLabel.font = TextPingFangFontSize(16);
    self.nameLabel.textColor = [UIColor blackTextColor];
    
    self.priceLabel.font = TextPingFangFontSize(14);
    self.priceLabel.textColor = [UIColor redF2color];
    
    self.oldLabel.font = TextPingFangFontSize(12);
    self.oldLabel.textColor = [UIColor grayTextColor];
    
    self.oldPriceLabel.font = TextPingFangFontSize(12);
    self.oldPriceLabel.textColor = [UIColor grayTextColor];
    
    self.oldPriceView.backgroundColor = [UIColor grayTextColor];
    
    [self.buyButton setTitle:@"去抢购" forState:UIControlStateNormal];
    [self.buyButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
    [self.buyButton addTarget:self action:@selector(buttonClick:) forControlEvents:UIControlEventTouchUpInside];
    self.buyButton.backgroundColor = [UIColor redF2color];
    self.buyButton.layer.cornerRadius = 2;
}

- (void)buttonClick:(UIButton *)sender {
    if (self.block) {
        self.block();
    }
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
